package org.dromara.customer.domain.bo;

import org.dromara.customer.domain.TaOrderDetail;
import org.dromara.common.mybatis.core.domain.BaseEntity;
import org.dromara.common.core.validate.AddGroup;
import org.dromara.common.core.validate.EditGroup;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import jakarta.validation.constraints.*;

/**
 * 订单明细业务对象 ta_order_detail
 *
 * @author xiyin321
 * @date 2024-07-09
 */
@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = TaOrderDetail.class, reverseConvertGenerate = false)
public class TaOrderDetailBo extends BaseEntity {

    /**
     * 主键
     */
    @NotNull(message = "主键不能为空", groups = { EditGroup.class })
    private Long id;

    /**
     * 订单ID
     */
    @NotNull(message = "订单ID不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long ordersId;

    /**
     * 店铺id
     */
    private Long storeId;

    /**
     * 店铺名称
     */
    private String storeName;

    /**
     * 图片
     */
    @NotNull(message = "图片不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long image;

    /**
     * 商品id/套餐id
     */
    @NotNull(message = "商品id/套餐id不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long goodsId;

    /**
     * 商品名称/套餐名称
     */
    @NotBlank(message = "商品名称/套餐名称不能为空", groups = { AddGroup.class, EditGroup.class })
    private String goodsName;

    /**
     * 已选列表
     */
    @NotBlank(message = "已选列表不能为空", groups = { AddGroup.class, EditGroup.class })
    private String selected;

    /**
     * 数量
     */
    @NotNull(message = "数量不能为空", groups = { AddGroup.class, EditGroup.class })
    private int number;

    /**
     * 金额
     */
    @NotBlank(message = "金额不能为空", groups = { AddGroup.class, EditGroup.class })
    private String amount;


}
